GtkPlacesSidebar: do not unref mount
authorAlban Browaeys <prahal@yahoo.com>
Fri, 24 May 2013 23:05:13 +0000 (01:05 +0200)
committerMatthias Clasen <mclasen@redhat.com>
Sun, 26 May 2013 04:03:13 +0000 (00:03 -0400)
Do not unref mount has we grabbed its pointer without taking
a reference.
Otherwise the following call to g_list_free_full on network_mounts
frees it a second time. Segfault in nautilus ensue.

https://bugzilla.gnome.org/show_bug.cgi?id=700979

gtk/gtkplacessidebar.c

index ed6af4a82decd6f54a6bd0d1abca91788cca8d99..63f7afe704efefca587d41c025cb1e329eeb0e21 100644 (file)
@@ -1123,7 +1123,6 @@ update_places (GtkPlacesSidebar *sidebar)
                           name, icon, mount_uri,
                           NULL, NULL, mount, 0, tooltip);
                g_object_unref (root);
-               g_object_unref (mount);
                g_object_unref (icon);
                g_free (name);
                g_free (mount_uri);